
#include"Test.h"

void Stack::Init(int defaultcapacity )
{
	a = (int*)malloc(sizeof(int) * defaultcapacity);
	if (a == nullptr)
	{
		perror("mallo fail");
		return;
	}
	capacity = defaultcapacity;
	top = 0;
}
